from django.db import models
from datetime import datetime

# Create your models here.

class Page_Profile(models.Model):
	url_id = models.AutoField(primary_key = True)
	url = models.TextField(unique=True)
	timestamp = models.DateTimeField()

class Sub_Components(models.Model):
	url = models.ForeignKey(Page_Profile)
	sub_url = models.TextField()
	obj_type = models.TextField()
	size = models.TextField()
	sub_type = models.TextField()
   
class View_Summary(models.Model):
	url_id = models.TextField()
	url = models.TextField()
	object_type = models.TextField()
	object_size = models.TextField()
	object_count  = models.TextField()

	class Meta:
		managed=False #eliminates table creation

class View_Total_Size(models.Model):
	url_id = models.TextField(primary_key = True)
	url = models.TextField()
	timestamp = models.DateTimeField()
	total_size = models.TextField() 

	class Meta:
		managed=False #eliminates table creation
